let express = require('express')
const router = express.Router()

const countryApi = require('./country')

module.exports = function() {
	[
		...countryApi
	].map( it => {
		router.post(
			it.path,
			(req,res)=>{
				it.request && it.request( req.body, res )
			}
		)
	} )

	return router
}
